from change_attribute import Car


class ElectricCar(Car):
    """
    电动汽车类
    """
    def __init__(self, make, model, year, battery_size=75):
        """
        :param battery_size: 电池容量,默认值为75kw*h
        """
        super().__init__(make, model, year)
        self.battery_size = battery_size

    def get_descriptive_name(self):
        return f"{super().get_descriptive_name()} 电池容量{self.battery_size}kw*h"


second_car = ElectricCar("BYD", "唐", 2023)
second_car.read_odometer()
print(second_car.get_descriptive_name())
